﻿@model IQueryable<SusuCMS.User>
@{
    ViewBag.Title = "Index".Localize();
}
<h2>
    @("Index".Localize())</h2>
@Html.Partial("HomeTabs")
<div class="toolbar">
    @Html.ActionLink("Create".Localize(), "Create", "User", null, new { @class = "button" })
</div>
@{
    var grid = new WebGrid(Model);
}
@using (Html.BeginForm("Delete", "User"))
{
    @grid.GetHtml(
        tableStyle: "data-table",
        columns: grid.Columns(
                grid.Column("Id", "Id".Localize()),
                grid.Column("UserName", "UserName".Localize()),
                grid.Column("Email", "Email".Localize()),
                grid.Column("CultureName", "CultureName".Localize()),
                grid.Column("CreateTime", "CreateTime".Localize()),
                grid.Column(header: "Edit".Localize(), format: (item) => Html.ActionLink("Edit".Localize(), "Edit", "Website", new { id = item.Id }, new { @class = "edit" })),
                grid.Column(header: "Delete".Localize(), format: (item) => Html.Raw(string.Format("<button type=\"submit\" value=\"{0}\" class=\"delete\">{1}</button>", item.Id, "Delete".Localize())))
        )
   )
} 